package com.ms.service.module.fish.message.server;

import java.nio.ByteBuffer;

import com.ms.service.module.fish.db.UsrGameLog;
import com.ms.service.module.fish.game.GameUser;
import com.ms.service.module.fish.message.FishBaseMessage;

/**
 * 炮弹攻击
 * @author cuiwm
 */
public class LabaMessage extends FishBaseMessage{
	
	private GameUser user;
	private UsrGameLog log;
    
    public LabaMessage(GameUser user,UsrGameLog log) {
    	this.setUser(user);
    	this.setLog(log);
	}

	public GameUser getUser() {
		return user;
	}

	public void setUser(GameUser user) {
		this.user = user;
	}

	public UsrGameLog getLog() {
		return log;
	}

	public void setLog(UsrGameLog log) {
		this.log = log;
	}

	@Override
	public void writeBody(ByteBuffer buf) {
//		buf.writeInt(user.getId().intValue());
		buf.putInt(log.getRate());
		buf.putInt(log.getAddCoin());
	}


}